

 /*
 * Team Name: Focus
 * Team Members: Diana Groun, Edward Bassan
 * File Name: debug.h
 * Description: Debug monitor simulator that will
 *  allow the display of registers, memory, and a menu of command options on the screen.
 */

#include "registerFile.h"
#include"memory.h"
#include"controller.h"
#include"alu.h"
#include "cpu.h"

#ifndef DEBUG_H_
#define DEBUG_H_


typedef struct debug {
	   //instance field
        ControllerPtr controller;
        // Functions
         int (*loadProgram ) (struct debug*);
         int (*runProgram) (struct debug*);
         int (*stepProgram) (struct debug*);
         int (*dumpMemory) (struct debug*);
         int (*showMemory) (struct debug*);
         int (*showRegisters) (struct debug*);
         int (*exitProgram) (struct debug*, int**);
         int (*displayMenu) (struct debug*, int*);
         int (*showAll) (struct debug*);
         int (*showUpdate)(struct debug*,int,int);




} debugStr;

typedef debugStr * debugPtr;

 debugPtr newDebug();
 int loadProgram (debugPtr this);
 int dumpMemory (debugPtr this);
 int runProgram (debugPtr this);
 int stepProgram (debugPtr this);
 int exitProgram (debugPtr this, int **exit);
 int displayMenu (debugPtr this, int *exit);
 int showRegisters(debugPtr this);
 int showMemory (debugPtr this);
 int showAll (debugPtr this);
 int showUpdate(debugPtr this,int start,int end);
 int getOperation(int operation, debugPtr this, int **exit);


#endif /* DEBUG_H_ */
